import { createRoot } from 'react-dom/client'
import './index.css'
import App from './App.tsx'
import { registerMicroApps, start } from 'qiankun'
import { BrowserRouter } from 'react-router-dom'
registerMicroApps([
  {
    name: 'project',
    entry: '//localhost:8001',
    container: '#Container',
    activeRule: '/project',
  },
  {
    name: 'team',
    entry: '//localhost:8002',
    container: '#Container',
    activeRule: '/team',
  },
  {
    name: 'docs',
    entry: '//localhost:8003',
    container: '#Container',
    activeRule: '/docs',
  },
  {
    name: 'data',
    entry: '//localhost:8004',
    container: '#Container',
    activeRule: '/data',
  },
  {
    name: 'system',
    entry: '//localhost:8005',
    container: '#Container',
    activeRule: '/system',
  },
]);
createRoot(document.getElementById('root')!).render(
  <BrowserRouter>
    <App />
  </BrowserRouter>
)
start();
